Pre-game files
Scripts that will be run on game startup.
gameflow.lua
AddLevel(level) | Add a level to the gameflow. |
SetIntroImagePath(path) | Image to show when loading the game. |
SetTitleScreenImagePath(path) | Image to show in the background of the title screen. |
SetGameFarView(farview) | Maximum draw distance. |
settings.lua
SetSettings(settings) |
tracks.lua
SetAudioTracks(table) |
strings.lua
SetStrings(table) | Set string variable keys and their translations. |
SetLanguageNames(table) | Set language names for translations. |
gameflow.lua
These functions are called in gameflow.lua, a file loosely equivalent to winroomedit's SCRIPT.DAT.
They handle a game's 'metadata'; i.e., things such as level titles, loading screen paths, and default
ambient tracks.
- AddLevel(level)
-
Add a level to the gameflow.
Parameters:
- level Level a level object
- SetIntroImagePath(path)
-
Image to show when loading the game.
Must be a .jpg or .png image.
Parameters:
- path string the path to the image, relative to the TombEngine exe
- SetTitleScreenImagePath(path)
-
Image to show in the background of the title screen.
Must be a .jpg or .png image.
(not yet implemented)
Parameters:
- path string the path to the image, relative to the TombEngine exe
- SetGameFarView(farview)
-
Maximum draw distance.
The maximum draw distance, in sectors (blocks), of any level in the game.
This is equivalent to TRNG's WorldFarView variable.
(not yet implemented)
Parameters:
- farview byte Number of sectors. Must be in the range [1, 127].
settings.lua
These functions are called in settings.lua, a file which holds your local settings.
settings.lua shouldn't be bundled with any finished levels/games.
tracks.lua
TODO CONFIRM PROPER BEHAVIOUR
- SetAudioTracks(table)
-
Parameters:
- table table array-style table with AudioTrack objects
strings.lua
These functions used in strings.lua, which is generated by TombIDE.
You will not need to call them manually.
- SetStrings(table)
-
Set string variable keys and their translations.
Parameters:
- table tab array-style table with strings
- SetLanguageNames(table)
-
Set language names for translations.
Specify which translations in the strings table correspond to which languages.
Parameters:
- table tab array-style table with language names